package com.tyfspring.beans.factory;

import com.tyfspring.beans.exception.BeansException;

/**
 * @Description 自动装配接口
 * @Author shallow
 * @Date 2023/3/26 13:58
 */
public interface AutowireCapableBeanFactory extends BeanFactory{

    /**
     * 执行beanpostProcessor中的postProcessBeforeInitialization方法
     * @param existingBean
     * @param beanName
     * @return
     * @throws BeansException
     */
    Object applyBeanPostProcessorBeforeInitialization(Object existingBean, String beanName) throws BeansException;

    /**
     * 执行BeanPostProcessors的postProcessAfterInitialization方法
     *
     * @param existingBean
     * @param beanName
     * @return
     * @throws BeansException
     */
    Object applyBeanPostProcessorsAfterInitialization(Object existingBean, String beanName)
            throws BeansException;
}
